//package com.jarvan.config;
//
//import org.springframework.context.annotation.Configuration;
//import org.springframework.security.config.annotation.method.configuration.EnableGlobalMethodSecurity;
//import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
//import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
//import org.springframework.security.core.userdetails.UserDetailsService;
//import org.springframework.security.web.access.AccessDeniedHandler;
//
//@Configuration
//@EnableWebSecurity
//@EnableGlobalMethodSecurity(prePostEnabled = true)
//public class WebSecurityConfig extends WebSecurityConfigurerAdapter {
//    private final JwtAuthenticationEntryPoint unauthorizedHandler;
//
//    private final AccessDeniedHandler accessDeniedHandler;
//
//    private final UserDetailsService customUserDetailsService;
//
//    private final JwtAuthenticationTokenFilter jwtAuthenticationTokenFilter;
//
//    public WebSecurityConfig(JwtAuthenticationEntryPoint unauthorizedHandler,
//                             AccessDeniedHandler accessDeniedHandler,
//                             UserDetailsService customUserDetailsService,
//                             JwtAuthenticationTokenFilter jwtAuthenticationTokenFilter) {
//        this.unauthorizedHandler = unauthorizedHandler;
//        this.accessDeniedHandler = accessDeniedHandler;
//        this.customUserDetailsService = customUserDetailsService;
//        this.jwtAuthenticationTokenFilter = jwtAuthenticationTokenFilter;
//    }
//}
